<template>
  <editmodel :options="options" :id="route.query.id"></editmodel>
</template>

<script lang="ts" setup>
import { ref, reactive, onMounted } from "vue";
import { useRoute } from "vue-router";
import editmodel from "../editModel/index.vue";
import { dataSourceType } from "@/type";
//data
const route = useRoute();

const options = reactive({
  message: "A组只能往B组拖到一个元素",
  group: {
    name: "itxst",
    put: false, //允许拖入
    pull: "clone",
  },
  componentList: [
    {
      type: "custom",
      header: "自定义组件",
      list: [
        { name: "单行输入", icon: "icon-a-singlelineinput", componentName: "input", isShowScene: true },
        { name: "多行输入", icon: "icon-a-multilineinput", componentName: "textArea", isShowScene: true },
        { name: "单选框", icon: "icon-a-Singleoption", componentName: "radio", isShowScene: true },
        { name: "多选框", icon: "icon-a-Multipleselection", componentName: "checkbox", isShowScene: true },
        { name: "下拉选框", icon: "icon-a-dropdownbox", componentName: "dropdownbox", isShowScene: true },
        { name: "日期", icon: "icon-calendar", componentName: "dateTime", isShowScene: true },
        {
          name: "单图上传",
          icon: "icon-a-Singleimageupload",
          componentName: "singleImgUpload",
          isShowScene: true,
          isRightAble: false,
        },
        {
          name: "多图上传",
          icon: "icon-a-Multiimageupload",
          componentName: "multiImgUpload",
        },
        { name: "视频上传", icon: "icon-a-Videouploading", componentName: "videoUpload" },
        { name: "音频上传", icon: "icon-a-Audiouploading", componentName: "audioUpload" },
        { name: "附件上传", icon: "icon-attachment", componentName: "enclosureUpload" },
        { name: "所在城市", icon: "icon-city", componentName: "localcity" },
        { name: "详细地址", icon: "icon-a-Fulladdress1", componentName: "address" },
        // { name: "组织", icon: "icon-organize", componentName: "organize" }, // 暂时不放开，该组件需要通过api获取数据
        // { name: "富文本", icon: "icon-a-Richtext", componentName: "ueditor" },
      ],
    },
    {
      type: "system",
      header: "系统组件",
      list: [
        {
          name: "浏览及内容页设置",
          icon: "icon-preview",
          componentName: "browseSetting",
          column: true,
          uniqe: 1,
        },
        {
          name: "评论设置",
          icon: "icon-comment",
          componentName: "commentSetting",
          column: true,
          uniqe: 1,
        },
        {
          name: "是否允许投稿",
          icon: "icon-contribute",
          componentName: "allowPost",
          column: true,
          uniqe: 1,
        },
        {
          name: "SEO标题",
          icon: "icon-a-seotitle",
          componentName: "seoTitle",
          column: true,
          uniqe: 1,
        },
        {
          name: "SEO关键字",
          icon: "icon-a-seokeywords",
          componentName: "seoKeyword",
          column: true,
          uniqe: 1,
        },
        {
          name: "SEO描述",
          icon: "icon-a-seodescription",
          componentName: "seoDesc",
          column: true,
          uniqe: 1,
        },
        {
          name: "显示在前台",
          icon: "icon-cycle",
          componentName: "showInLoop",
          column: true,
          uniqe: 1,
        },
        // { name: '栏目页是否包含分页', icon: 'icon-paging', componentName: 'pagination', column: true, uniqe: 1 },
        {
          name: "栏目描述",
          icon: "icon-a-seodescription",
          componentName: "columnDesc",
          column: true,
          uniqe: 1,
        },
        {
          name: "栏目图片",
          icon: "icon-a-Singleimageupload",
          componentName: "columnImage",
          column: true,
          uniqe: 1,
        },
        { name: '外部链接', icon: 'icon-comment', componentName: 'outLink', column: true, uniqe: 1 },
        /*workflow-plugin start*/
        {
          name: "工作流设置",
          icon: "icon-workflow",
          componentName: "workFlowSetting",
          column: true,
          uniqe: 1,
        },
        /*workflow-plugin end*/
        {
          name: "栏目手机端模板",
          icon: "icon-comment",
          componentName: "tplMobile",
          column: true,
          uniqe: 1,
        },
        {
          name: "栏目PC端模板",
          icon: "icon-comment",
          componentName: "tplPc",
          column: true,
          uniqe: 1,
        },
        {
          name: "内容模板",
          icon: "icon-comment",
          componentName: "contentModelTpls",
          column: true,
          uniqe: 1,
        },
        { name: "富文本", icon: "icon-a-Richtext", componentName: "ueditor", column: true,
          uniqe: 1,},
        // { name: '信息类别码', icon: 'icon-a-Classcode', componentName: 'categoryCode', column: true, uniqe: 1 },
        // { name: '内容列表每页显示内容数', icon: 'icon-a-Contentnumber', componentName: 'contentnumber', column: true, uniqe: 1 },
      ],
    },
  ],
});
</script>

<style lang="less" scoped></style>
